
CFLAGS	=-m32 -Wall -O0 -fstrength-reduce -fomit-frame-pointer \
	-finline-functions -fno-stack-protector \
	-Icmocka/include -Lcmocka/lib

EXT_INCS =

CFLAGS += $(EXT_INCS)

TARGET = run_test
SRCS = main.c test_vsprintf.c
OBJS = $(SRCS:.c=.o)

%.o: %.c
	$(CC) $(CFLAGS) -c $< -o $@

$(TARGET): $(OBJS)
	$(CC) $(CFLAGS) $(LDFLAGS) -o $@ $^ -lcmocka

.PHONY: clean
clean:
	rm -f $(OBJS) $(TARGET)